package co.com.mobileandbusiness.alarmas.persistencia.dao;

import java.io.Serializable;
import java.util.List;

public interface IDAO <T , O extends Serializable>{
		
	public T getById(Class<T> type,O id);

	public void update(T object);

	public void save(T object);

	public void delete(T object);

	public void deleteById(Class<T> type, O id);
	
	public List<T> getByExample(T object);

	public List<T> getList(Class<T> type, String orderBy, boolean orderAsc);
	
	public List<T> getProjectedList(Class<T> type, List<String> propertiesNames, String orderBy, boolean orderAsc);
	
	public List<T> getPagedList(Class<T> type,int page,int pageSize, String orderBy, boolean orderAsc);
	
	public List<T> getPagedListByExample(T object,int page,int pageSize, String orderBy, boolean orderAsc);
	
	public void initialize(T object);
	
	public int count(Class<T> type);
	
	public int countByExample(T object);

}
